<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--
  Created by IntelliJ IDEA.
  User: 23649
  Date: 2021/5/8
  Time: 9:26
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <%
        String paths = request.getContextPath();
        String basePaths = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+paths+"/";
    %>
    <link rel="icon" type="image/x-icon" href="<%=basePaths%>/user/img/huaziloge.ico"/>
    <title>Title</title>
    <style type="text/css">

        #logo{
            font-size: 40px;
            font-family: "新宋体";
            color: #009688;
            margin-left: 150px;
        }
        #logo span{
            font-size: 25px;
            color: black;
        }
        #input1,#input2,#input3,#input4,#input5{
            margin-left: 550px;
            margin-top: 20px;
            border: 1px solid black;
        }
        #input6{
            margin-left: 720px;
            margin-top: 20px;
        }
    </style>
    <meta charset="utf-8">
    <title>华子医院</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" href="<%=basePaths%>layui-v2.6.5/layui/css/layui.css"  media="all">
</head>
<body>
<div id="hread" >
    <p id="logo"><img src="<%=basePaths%>img/loge.gif" STYLE="height: 180PX; width: 180PX">华子医院 <span>账户安全</span></p>
</div>
<div id="update">
    <form action="<%=basePaths%>update" method="post">
        <div class="layui-input-block" id="ruselt">
            <input name="idCard"  id="input1" type="text" name="title" lay-verify="title" autocomplete="off" placeholder="请输入身份证号码" class="layui-input" style="width: 400px" value="${idCard}">
            <input name="account" id="input2" type="text" name="title" lay-verify="title" autocomplete="off" placeholder="诊疗卡号" class="layui-input" style="width: 400px" value="${account}">
            <input name="phone" id="input3" type="text" name="title" lay-verify="title" autocomplete="off" placeholder="手机号码" class="layui-input" style="width: 400px" value="${phone}">
            <input name="name" id="input4" type="text" name="title" lay-verify="title" autocomplete="off" placeholder="姓名" class="layui-input" style="width: 400px" value="${name}">
            <input name="pwd"  id="input5" type="password" name="title" lay-verify="title" autocomplete="off" placeholder="新密码" class="layui-input" style="width: 400px" value="${pwd}">
            <input id="input6" type="submit" class="layui-btn" >
        </div>s
    </form>
</div>
<img  src="<%=basePaths%>img/dibu.jpg"  style="width: 1425px; " >
<script src="<%=basePaths%>layui-v2.6.5/layui/layui.js"></script>
<script src="<%=basePaths%>jquery-1.12.4.js"></script>
<script type="text/javascript">
    $(function (){
        $("form").submit(function (){
            if($("#input1").val()==""||$("#input2").val()==""||$("#input3").val()==""||$("#input4").val()==""||$("#input5").val()==""){
                    alert("请填入完整信息")
                    return false;
            }
        })
    })
</script>
<c:if test="${result eq 'no'}">
    <script type="text/javascript">
        alert("资料填入有误，请校验后重新输入");
    </script>
</c:if>
<c:if test="${result eq 'yes'}">
    <script type="text/javascript">
        alert("修改成功返回登录界面3s后自动跳转到登录界面");
        setTimeout(login,3000)
        function  login(){
            window.open("<%=basePaths%>user/login/welcome.jsp")
        }
    </script>
</c:if>
<script>
    //JavaScript代码区域
    // layui.use('element', function(){
    //     var element = layui.element;
    //
    // });

</script>
</body>
</html>
